package com.simulation.web.domain;

import lombok.Data;

import java.util.Date;

@Data
public class TechReply {
	/** 回复ID，主键，自增 */
	private Long id;
	/** 回复内容 */
	private String content;
	/** 用户ID */
	private Long userId;
	/** 被回复的评论ID，可空 */
	private Long commentId;
	/** 被回复用户的ID，可空 */
	private Long replyToUserId;
	/** 项目ID */
	private Long postId;
	/** 被回复的回复 */
	private Long replyId;
	/** 回复时间，默认当前时间 */
	private Date replyTime;

	@Override
    public boolean equals(Object o) {
        if (this == o) { return true; }
        if (o == null || getClass() != o.getClass()) {return false;}
        TechReply that = (TechReply) o;
        return id.equals(that.id);
    }

    @Override
    public int hashCode() {
        return java.util.Objects.hash(id);
    }
    
    @Override
    public String toString() {
        return "TechReply{" +
				"id=" + id +
						",content='" + content + "'" + 
						",userId='" + userId + "'" + 
						",commentId='" + commentId + "'" + 
						",replyToUserId='" + replyToUserId + "'" + 
						",postId='" + postId + "'" + 
						",replyTime='" + replyTime + "'" + 
		                '}';
    }
	
}